This disclosure relates to database queries. Electronic database systems may be used to collect, store, organize, and retrieve large amounts of information. Such database systems may provide an efficient and organized mechanism for multiple users to interact with information. As one example, enterprise software systems, such as inventory management systems, budget planning systems, and order management systems may support many, e.g., hundreds or thousands, of concurrent users. Such large-scale systems may store large amounts of information in one or more databases, such as multidimensional databases, relational databases, hierarchical databases, object-oriented databases, and the like.
In certain examples, as in a relational database, information is organized using tables, including rows and columns, which specify data or relations among tables. Information is retrieved from the database using queries issued to a database management system. For example, structured query language (SQL) queries may be used to retrieve data from one or more tables of a database. In some examples, a query may include a command to select information from two or more tables of a database (e.g., a join command). Similarly, some queries include commands to summarize or otherwise aggregate data from multiple tables.
Such queries may require the database management system to operate over large amounts of data. For instance, in a data warehouse environment, a database management system may operate over terabytes of data, performing multiple joins or other aggregation operations, thereby resulting in long response times. To improve efficiency and reduce response times, some database systems utilize pre-joined tables that include information derived from two or more tables.